<?php

namespace App\Models\Entity;

use Swoft\Db\Model;
use Swoft\Db\Bean\Annotation\Column;
use Swoft\Db\Bean\Annotation\Entity;
use Swoft\Db\Bean\Annotation\Id;
use Swoft\Db\Bean\Annotation\Required;
use Swoft\Db\Bean\Annotation\Table;

/**
 * 商品价格表

 * @Entity()
 * @Table(name="o_price")
 * @uses      OPrice
 * @version   2018年07月04日
 */
class OPrice extends Model
{
    /**
     * @var int $shopid 商品ID
     * @Id()
     * @Column(name="shopid", type="integer")
     */
    private $shopid;

    /**
     * @var int $shoptype 商品类型 11.话费快充 12.话费慢充 13.联通固话 14.联通宽带 15.电信固话 16.电信宽带 21.流量漫游月包 22.流量本地月包 23.流量漫游日包 24.流量本地日包 25.漫游三日包  26.本地三日包  27.漫游七日包  28.本地七日 31.腾讯Q币 32.中石化加油卡 33.中石油加油卡
     * @Column(name="shoptype", type="tinyint", default="0")
     */
    private $shoptype;

    /**
     * @var string $corp 运营商
     * @Column(name="corp", type="string", length=5, default="")
     */
    private $corp;

    /**
     * @var string $province 归属省份
     * @Column(name="province", type="string", length=10, default="")
     */
    private $province;

    /**
     * @var int $amount 支持面值
     * @Column(name="amount", type="integer", default="0")
     */
    private $amount;

    /**
     * @var float $inprice 基本售价
     * @Column(name="inprice", type="decimal", default="0.000")
     */
    private $inprice;

    /**
     * @var int $isopen 是否开放 0.关闭 1.开放
     * @Column(name="isopen", type="tinyint", default="0")
     */
    private $isopen;

    /**
     * @var int $btype 
     * @Column(name="btype", type="tinyint", default="1")
     */
    private $btype;

    /**
     * @var string $bid1 渠道1
     * @Column(name="bid1", type="string", length=32)
     */
    private $bid1;

    /**
     * @var string $bid2 渠道2
     * @Column(name="bid2", type="string", length=32)
     */
    private $bid2;

    /**
     * @var string $bid3 渠道3
     * @Column(name="bid3", type="string", length=32)
     */
    private $bid3;

    /**
     * @var string $bid4 渠道4
     * @Column(name="bid4", type="string", length=32)
     */
    private $bid4;

    /**
     * @var float $profit 昨日利润
     * @Column(name="profit", type="decimal", default="0.0000")
     */
    private $profit;

    /**
     * @var float $profitnow 今日利润
     * @Column(name="profitnow", type="decimal", default="0.0000")
     */
    private $profitnow;

    /**
     * @var string $uptime 更新时间
     * @Column(name="uptime", type="timestamp")
     */
    private $uptime;

    /**
     * @var string $split 拆分规则
     * @Column(name="split", type="string", length=50)
     */
    private $split;

    /**
     * 商品ID
     * @param int $value
     * @return $this
     */
    public function setShopid(int $value)
    {
        $this->shopid = $value;

        return $this;
    }

    /**
     * 商品类型 11.话费快充 12.话费慢充 13.联通固话 14.联通宽带 15.电信固话 16.电信宽带 21.流量漫游月包 22.流量本地月包 23.流量漫游日包 24.流量本地日包 25.漫游三日包  26.本地三日包  27.漫游七日包  28.本地七日 31.腾讯Q币 32.中石化加油卡 33.中石油加油卡
     * @param int $value
     * @return $this
     */
    public function setShoptype(int $value): self
    {
        $this->shoptype = $value;

        return $this;
    }

    /**
     * 运营商
     * @param string $value
     * @return $this
     */
    public function setCorp(string $value): self
    {
        $this->corp = $value;

        return $this;
    }

    /**
     * 归属省份
     * @param string $value
     * @return $this
     */
    public function setProvince(string $value): self
    {
        $this->province = $value;

        return $this;
    }

    /**
     * 支持面值
     * @param int $value
     * @return $this
     */
    public function setAmount(int $value): self
    {
        $this->amount = $value;

        return $this;
    }

    /**
     * 基本售价
     * @param float $value
     * @return $this
     */
    public function setInprice(float $value): self
    {
        $this->inprice = $value;

        return $this;
    }

    /**
     * 是否开放 0.关闭 1.开放
     * @param int $value
     * @return $this
     */
    public function setIsopen(int $value): self
    {
        $this->isopen = $value;

        return $this;
    }

    /**
     * @param int $value
     * @return $this
     */
    public function setBtype(int $value): self
    {
        $this->btype = $value;

        return $this;
    }

    /**
     * 渠道1
     * @param string $value
     * @return $this
     */
    public function setBid1(string $value): self
    {
        $this->bid1 = $value;

        return $this;
    }

    /**
     * 渠道2
     * @param string $value
     * @return $this
     */
    public function setBid2(string $value): self
    {
        $this->bid2 = $value;

        return $this;
    }

    /**
     * 渠道3
     * @param string $value
     * @return $this
     */
    public function setBid3(string $value): self
    {
        $this->bid3 = $value;

        return $this;
    }

    /**
     * 渠道4
     * @param string $value
     * @return $this
     */
    public function setBid4(string $value): self
    {
        $this->bid4 = $value;

        return $this;
    }

    /**
     * 昨日利润
     * @param float $value
     * @return $this
     */
    public function setProfit(float $value): self
    {
        $this->profit = $value;

        return $this;
    }

    /**
     * 今日利润
     * @param float $value
     * @return $this
     */
    public function setProfitnow(float $value): self
    {
        $this->profitnow = $value;

        return $this;
    }

    /**
     * 更新时间
     * @param string $value
     * @return $this
     */
    public function setUptime(string $value): self
    {
        $this->uptime = $value;

        return $this;
    }

    /**
     * 拆分规则
     * @param string $value
     * @return $this
     */
    public function setSplit(string $value): self
    {
        $this->split = $value;

        return $this;
    }

    /**
     * 商品ID
     * @return mixed
     */
    public function getShopid()
    {
        return $this->shopid;
    }

    /**
     * 商品类型 11.话费快充 12.话费慢充 13.联通固话 14.联通宽带 15.电信固话 16.电信宽带 21.流量漫游月包 22.流量本地月包 23.流量漫游日包 24.流量本地日包 25.漫游三日包  26.本地三日包  27.漫游七日包  28.本地七日 31.腾讯Q币 32.中石化加油卡 33.中石油加油卡
     * @return mixed
     */
    public function getShoptype()
    {
        return $this->shoptype;
    }

    /**
     * 运营商
     * @return mixed
     */
    public function getCorp()
    {
        return $this->corp;
    }

    /**
     * 归属省份
     * @return mixed
     */
    public function getProvince()
    {
        return $this->province;
    }

    /**
     * 支持面值
     * @return mixed
     */
    public function getAmount()
    {
        return $this->amount;
    }

    /**
     * 基本售价
     * @return float
     */
    public function getInprice()
    {
        return $this->inprice;
    }

    /**
     * 是否开放 0.关闭 1.开放
     * @return mixed
     */
    public function getIsopen()
    {
        return $this->isopen;
    }

    /**
     * @return int
     */
    public function getBtype()
    {
        return $this->btype;
    }

    /**
     * 渠道1
     * @return mixed
     */
    public function getBid1()
    {
        return $this->bid1;
    }

    /**
     * 渠道2
     * @return mixed
     */
    public function getBid2()
    {
        return $this->bid2;
    }

    /**
     * 渠道3
     * @return mixed
     */
    public function getBid3()
    {
        return $this->bid3;
    }

    /**
     * 渠道4
     * @return mixed
     */
    public function getBid4()
    {
        return $this->bid4;
    }

    /**
     * 昨日利润
     * @return float
     */
    public function getProfit()
    {
        return $this->profit;
    }

    /**
     * 今日利润
     * @return float
     */
    public function getProfitnow()
    {
        return $this->profitnow;
    }

    /**
     * 更新时间
     * @return mixed
     */
    public function getUptime()
    {
        return $this->uptime;
    }

    /**
     * 拆分规则
     * @return mixed
     */
    public function getSplit()
    {
        return $this->split;
    }

}
